import { Column, Entity } from "typeorm";
import { BaseEntity } from "../../base/entity/base";

@Entity('user_favorite')
export class UserFavoriteEntity extends BaseEntity {
    @Column({ comment: '用户ID' })
    userId: number;

    @Column({ comment: '关联ID' })
    relatedId: number;

    @Column({ comment: '关联类型' })
    relatedType: 'product' | 'provider';

    @Column({ comment: '关联名称', length: 255 })
    relatedName: string;
}